<script src="/assets/js/jquery.bootbox.min.js"></script>
<script src="/b/<%=branch%>/proxy/config?key=item,unit,chip,egg,box,itemGroup,unitBase,gem,MsgList,"></script>
<script src="/assets/item.js"></script>
<script>
    var key_list = cosjs.option('paycode');
    function afterShowForm(e,isEdit){
        $("#icon").attr("title","活动图标").tooltip({container:'body'});
        $("#style").attr("title","模板样式,比如背景图片等").tooltip({container:'body'});
        if(isEdit ){
            var status = $("#status").val();
            if(status > 0){
                $("#AKey").attr("disabled","disabled");
                $("#AType").attr("disabled","disabled");
            }
        }
        else {
            $("#skin").val(0);
        }
    }

    var NewsColModel = [

        {label: '充值代码', name: 'key',width: 150, editable: true, sortable:false,hidden:false,resize:false,fixed:true,search:true,
            formatter:'select', edittype:'select', editoptions:{value:key_list},
            stype:"select",
            searchoptions:{sopt:['eq'],value:key_list}
        },

        {label: '成就点数', name: 'rmb',width: 80, editable: true, sortable:false,hidden:false,resize:true,fixed:false,search:false,},

        {label: '限购次数', name: 'limit',width: 80, editable: true, sortable:false,hidden:false,resize:true,fixed:false,search:false,},

        {label: '充值图标', name: 'icon',width: 80, editable: true, sortable:false,hidden:true,resize:true,fixed:false,search:false,editrules: { edithidden: true },},

        {label: '模板样式', name: 'style',width: 80, editable: true, sortable:false,hidden:true,resize:true,fixed:false,search:false,
            editrules: { edithidden: true },
        },

        {label: '获得道具', name: 'item', width: 200, editable: true,sortable:false, resize:true,search:false,fixed:false,
            formatter:cosjs.item.formatter,
            unformat:cosjs.item.unformat,
            editoptions: { dataInit: function (element) { new cosjs.item.select(element); } }
        },

        {label: '充值说明', name: 'desc',width: 180, editable: true, sortable:false,hidden:true,resize:true,fixed:false,search:false,
            editrules: { edithidden: true },
            edittype:'textarea',editoptions:{rows:"1",cols:"73"},
        },
    ];


</script>

